package com.yxw.live_vod_backend_boot.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 商品实体类 yx_product
 *
 * @author xiexuxin
 * @date 2023-12-07
 */
@Data
@TableName("yx_product")
@ApiModel("商品实体类")
public class YxProductEntity implements Serializable {
    private static final long serialVersionUID = 1L;

    @TableId(value = "product_id",type = IdType.ASSIGN_ID)
    @ApiModelProperty("商品Id")
    private Long productId;

    @TableField("product_name")
    @ApiModelProperty("商品名称")
    private String productName;

    @TableField("product_master_pic")
    @ApiModelProperty("商品主图")
    private String productMasterPic;

    @TableField("product_detail_pic")
    @ApiModelProperty("商品详情图")
    private String productDetailPic;

    @TableField("user_id")
    @ApiModelProperty("用户Id")
    private Long userId;

    @TableField("user_name")
    @ApiModelProperty("用户名称")
    private String userName;

    @TableField("shop_id")
    @ApiModelProperty("店铺Id")
    private Long shopId;

    @TableField("shop_name")
    @ApiModelProperty("店铺名称")
    private String shopName;

    @TableField("category_id")
    @ApiModelProperty("类目Id")
    private Long categoryId;

    @TableField("product_category")
    @ApiModelProperty("类目名称")
    private String productCategory;

    @TableField("product_specification")
    @ApiModelProperty("商品规格")
    private String productSpecification;

    @TableField("buss_id")
    @ApiModelProperty("直播/点播Id")
    private Long bussId;

    @TableField("product_url")
    @ApiModelProperty("商品链接")
    private String productUrl;

    @TableField("product_series_num")
    @ApiModelProperty("商品系列号")
    private String productSeriesNum;

    @TableField("product_price")
    @ApiModelProperty("商品价格")
    private BigDecimal productPrice;

    @TableField("cut_price")
    @ApiModelProperty("促销价格")
    private BigDecimal cutPrice;

    @TableField("discount")
    @ApiModelProperty("折扣")
    private BigDecimal discount;

    @TableField("total_cnt")
    @ApiModelProperty("库存")
    private Integer totalCnt;

    @TableField("pree_cnt")
    @ApiModelProperty("预占量")
    private Integer preeCnt;

    @TableField("use_cnt")
    @ApiModelProperty("实占量")
    private Integer useCnt;

    @TableField("product_status")
    @ApiModelProperty("商品状态 0在售 1停售")
    private Integer productStatus;

    @TableField("product_num")
    @ApiModelProperty("商品编号")
    private String productNum;

    @TableField("purchase_notes")
    @ApiModelProperty("购买须知")
    private String purchaseNotes;

    @TableField("create_time")
    @ApiModelProperty("创建时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    @TableField("update_time")
    @ApiModelProperty("更新时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    @TableField("remark")
    @ApiModelProperty("备注")
    private String remark;

    @TableField("style")
    @ApiModelProperty("款式")
    private String style;

    @TableField("pic_buss_id")
    @ApiModelProperty("图片业务ID")
    private Long picBussId;

}
